home *** CD-ROM | disk | FTP | other *** search
/ The Atari Compendium / The Atari Compendium (Toad Computers) (1994).iso / files / prgtools / programm.ing / ams__l~1.zoo / man / easyspri.man < prev    next >
Encoding:
Text File  |  1993-09-05  |  2.7 KB  |  92 lines

  1.                         ATARI MACHINE SPECIFIC LIBRARY
  2.  
  3.  
  4.  
  5. NAME
  6.      EasySprite - simplified sprite creation routines
  7.  
  8. SYNOPSIS
  9.      #include <EasySprite.h>
  10.  
  11.      Sprite* GetSprite(Screen&,int x,int y,int h,int attr,
  12.                  int n=1,int dx=16,int dy=0);
  13.  
  14.      Sprite* GetMobileSprite(Screen&,int x,int y,int h,int attr,
  15.                  int n=1,int dx=16,int dy=0);
  16.  
  17.      Incarnation* GetIncarnation(Screen& S,int x,int y,int h,int attr);
  18.  
  19.      #define ...
  20.  
  21. DESCRIPTION
  22.      For many purposes, the creation facilities of the Incarnation,
  23.      Sprite and MobileSprite classes are too general - and take a
  24.      large about of code to set-up individual sprite incarnations.
  25.  
  26.      When the programmer wants to create a sprite with a homogeneous
  27.      type of incarnation (eg. all 16x16 Colour ones) by loading them
  28.      from a screen drawn with a drawing program, these functions
  29.      suffice.
  30.  
  31. FUNCTIONS
  32.  
  33.      Sprite* GetSprite(Screen&,int x,int y,int h,int attr,
  34.                  int n=1,int dx=16,int dy=0);
  35.  
  36.      Sprite* GetMobileSprite(Screen&,int x,int y,int h,int attr,
  37.                  int n=1,int dx=16,int dy=0);
  38.  
  39.        Get a Sprite or MobileSprite from the given Screen, using the n
  40.        images of height h, from (x,y) in steps of (+dx,+dy).  All
  41.        Incarnations in the Sprite will have attributes as close as
  42.        possible to those requested. (See CONSTANTS below)
  43.  
  44.      Incarnation* GetIncarnation(Screen& S,int x,int y,int h,int attr);
  45.        Get an Incarnation of the given height from (x,y) on the given
  46.        screen, with attributes as close as possible to those requested.
  47.  
  48. CONSTANTS
  49.      The attributes requested by the above functions should be a
  50.      combination of one or more of these:
  51.  
  52.      SP_MONO
  53.        Monochrome
  54.  
  55.      SP_COLOUR
  56.        16-Colour
  57.  
  58.      SP_WIDE
  59.        32 pixels wide
  60.  
  61.      SP_FAST
  62.        Faster, but use 32 times as much memory
  63.  
  64.      SP_HOTCENTRE
  65.        Hot spot of incarnations placed in there centre
  66.  
  67. USAGE
  68.      Load a screen, then extract images with the above functions.
  69.      The screen need no longer exist once images are extracted.
  70.  
  71. EXAMPLES
  72.      Screen images("sprites.pi1");
  73.      Sprite* spaceship=GetSprite(images,32,50,16,SP_COLOUR);
  74.  
  75. SEE ALSO
  76.      Sprite, MobileSprite, Screen
  77.  
  78. AUTHOR
  79.      Warwick Allison, 1992.
  80.      warwick@cs.uq.oz.au
  81.  
  82. COPYING
  83.      This functionality is part of the Atari Machine Specific Library,
  84.      and is Copyright 1992 by Warwick W. Allison.
  85.  
  86.      The Atari Machine Specific Library is free and protected under the
  87.      GNU Library General Public License.
  88.  
  89.      You are free to copy and modify these sources, provided you acknowledge
  90.      the origin by retaining this notice, and adhere to the conditions
  91.      described in the GNU LGPL.
  92.